Data Control Block
   HOME

TheInfoList



OR:

In
IBM mainframe IBM mainframes are large computer systems produced by IBM since 1952. During the 1960s and 1970s, IBM dominated the large computer market. Current mainframe computers in IBM's line of business computers are developments of the basic design of th ...
operating system An operating system (OS) is system software that manages computer hardware, software resources, and provides common services for computer programs. Time-sharing operating systems schedule tasks for efficient use of the system and may also i ...
s, such as
OS/360 OS/360, officially known as IBM System/360 Operating System, is a discontinued batch processing operating system developed by IBM for their then-new System/360 mainframe computer, announced in 1964; it was influenced by the earlier IBSYS/IBJOB ...
,
MVS Multiple Virtual Storage, more commonly called MVS, was the most commonly used operating system on the System/370 and System/390 IBM mainframe computers. IBM developed MVS, along with OS/VS1 and SVS, as a successor to OS/360. It is unrelated ...
,
z/OS z/OS is a 64-bit operating system for IBM z/Architecture mainframes, introduced by IBM in October 2000. It derives from and is the successor to OS/390, which in turn was preceded by a string of MVS versions.Starting with the earliest: * ...
, a Data Control Block (DCB) is a description of a
dataset A data set (or dataset) is a collection of data. In the case of tabular data, a data set corresponds to one or more database tables, where every column of a table represents a particular variable, and each row corresponds to a given record of the ...
in a program. A DCB is coded in
Assembler Assembler may refer to: Arts and media * Nobukazu Takemura, avant-garde electronic musician, stage name Assembler * Assemblers, a fictional race in the ''Star Wars'' universe * Assemblers, an alternative name of the superhero group Champions of ...
programs using the DCB macro instruction (which expands into a large number of "define constant" instructions). High level language programmers use library routines containing DCBs. A DCB is one of the many ''control blocks'' used in these operating systems. A ''control block'' is a data area with a predefined structure, very similar to a C struct, but typically only related to system's functions. A DCB may be compared to a FILE structure in C, but it is much more complex, offering many more options for various access methods. The control block acted as the Application programming interface between Logical IOCS and the
application program Application may refer to: Mathematics and computing * Application software, computer software designed to help the user to perform specific tasks ** Application layer, an abstraction layer that specifies protocols and interface methods used in a c ...
and usually was defined within (and resided within) the application program itself. The addresses of I/O subroutines would be resolved during a linkedit phase after compilation or else dynamically inserted at OPEN time. The equivalent control block for IBM DOS/360, DOS/VSE and
z/VSE VSEn (''Virtual Storage Extended'') is an operating system for IBM mainframe computers, the latest one in the DOS/360 lineage, which originated in 1965. DOS/VSE was introduced in 1979 as a successor to DOS/VS; in turn, DOS/VSE was succeeded by ...
operating systems is a "DTF" (Define the fil


Typical contents of a DCB

* symbolic file name (to match a Job Control Language, JCL statement for opening the file) * type of access (e.g. random, sequential, indexed) * physical characteristics ( blocksize, logical record length) * number of I/O buffers to allocate for processing to permit overlap of I/O * address of I/O
operating system An operating system (OS) is system software that manages computer hardware, software resources, and provides common services for computer programs. Time-sharing operating systems schedule tasks for efficient use of the system and may also i ...
library subroutines (e.g. read/write) * other variables as required by the subroutines according to type


Prototype DCBs

Many of the constants and variables contained within a DCB may be left blank (i.e., these default to zero). The OPEN process results in a ''merge'' of the constants and variables specified in the DD JCL statement, and the dataset label for existing magnetic tape and direct-access datasets, into the DCB, replacing the zero values with actual, non-zero values. A control block called the JFCB (Job File Control Block) initially holds the information extracted from the DD statement for the dataset. The results of the merge are stored in the JFCB which may also be written into the DSCB during the CLOSE process, thereby making the dataset definition permanent. An example is the BLKSIZE= variable, which may be (and usually is) specified in the DCB as zero. In the DD statement, the BLKSIZE is specified as a non-zero value and this, then, results in a program-specified LRECL (logical record length) and a JCL-specified BLKSIZE (physical block size), with the merge of the two becoming the permanent definition of the dataset.


See also

* Data Set Control Block (DSCB), a part of VTOC IBM mainframe operating systems {{mainframe-compu-stub